package com.heriparid.fragmentinjection.ui;

import java.util.List;

import javax.inject.Inject;

import android.location.LocationManager;
import android.os.Bundle;
import android.widget.Button;
import android.widget.TextView;
import butterknife.InjectView;
import butterknife.OnClick;

import com.heriparid.fragmentinjection.BaseActivity;
import com.heriparid.fragmentinjection.R;

public class LoginActivity extends BaseActivity {

	@InjectView(R.id.btn_ok) Button btnOk;
	@InjectView(R.id.tv_helloworld) TextView txtHelloWorld;
	
	@Inject
	LocationManager mLocationManager;
	
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		
		setContentView(R.layout.login_layout);
		super.onCreate(savedInstanceState);
		
	}
	
	@OnClick(R.id.btn_ok)
	public void onBtnOkClick(){
		
		List<String> providers = mLocationManager.getAllProviders();
		txtHelloWorld.setText(String.valueOf(providers.size()));
	}
	
}
